// 学生的综合评价
class StudentEvaluate {
    String attendance = '' // 考勤
    String homework = '' // 作业/测试情况
    String expression = '' // 课堂表现
    String complex = '' // 课堂表现
    Date createTime = new Date()
    Student student //被考评的学生
    Teacher postTeacher // 考评老师

    static constraints = {
        attendance(size: 1..1000)
        expression(size: 1..1000)
        homework(size: 1..1000)        
        complex(size: 1..1000)
        student()
        postTeacher(nullable:true)
    }

    static mapping = {
       table 'xedu_student_evaluate'
       createTime column:'create_time' 
       postTeacher column:'post_teacher' 
    }

    String toString() {
        "${student.name} ${createTime.format('yyyy/MM/dd')}"
    }
}
